﻿using System;
using UnityEngine;

namespace Gp.Scripts.GUI.VFX {
    public class VFXFade : MonoBehaviour {
        public float lifeTime = 5f;

        private float _timeCount = 0;
        
        private void Update() {
            _timeCount += Time.deltaTime;
            if (_timeCount > lifeTime) {
                Destroy(this.gameObject);
            }
        }
    }
}